package com.slg.android.listenbook.biz.bookcity.model;

import org.json.JSONException;
import org.json.JSONObject;

/**
 * Created by Darker on 2015/3/24.
 */
public class CategoryDetail {

    private String id;
    private String name;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public void parseCategoryDetail(JSONObject jsonObject){
       if(jsonObject != null){
           try {
               name = jsonObject.getString("name");
               id = jsonObject.getString("id");
           } catch (JSONException e) {
               e.printStackTrace();
           }
       }
    }
}
